package com.das.mechanic_base.adapter.main;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;

import com.das.mechanic_base.R;

import java.util.ArrayList;
import java.util.List;

public class X3MaintenancePlanAdapter extends RecyclerView.Adapter<X3MaintenancePlanAdapter.MaintenancePlanHolder> {

    private List<String> mList;

    private Context mContext;

    public X3MaintenancePlanAdapter(Context mContext) {
        this.mContext = mContext;
        this.mList = new ArrayList<>();


    }
    public void setDataList(List<String> mList) {
        this.mList = mList;
        notifyDataSetChanged();
    }


    @NonNull
    @Override
    public X3MaintenancePlanAdapter.MaintenancePlanHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
        return new X3MaintenancePlanAdapter.MaintenancePlanHolder(LayoutInflater.from(mContext).inflate(R.layout.x3_car_question_item,parent,false));
    }

    @Override
    public void onBindViewHolder(@NonNull X3MaintenancePlanAdapter.MaintenancePlanHolder holder, int position) {


    }

    IOnSelectStyle iOnSelectStyle;

    public void setiOnSelectStyle(IOnSelectStyle iOnSelectStyle) {
        this.iOnSelectStyle = iOnSelectStyle;
    }

    public interface IOnSelectStyle {

    }

    @Override
    public int getItemCount() {
        return mList.size();
    }

    class MaintenancePlanHolder extends RecyclerView.ViewHolder {

        public MaintenancePlanHolder(@NonNull View itemView) {
            super(itemView);


        }
    }
}
